<cfcomponent displayname="Creation">
    
    <cfproperty name="DOMAINCONTROLLER" default="10.100.1.101" />
    <cfproperty name="ORG_SCF" default="117" />
    <cfproperty name="DOLLARS" default="2" />
	<cfproperty name="USA" default="5" />
    <cfproperty name="Error" default="False" />
    <cfproperty name="EmpStatusReason" default="" />
    <cfproperty name="StepID" default="-1" />
    <cfproperty name="ErrorMessage" defualt="" />
    <cfproperty name="Manual" defualt="0" />	
	<cfproperty name="PRIMARY_POS" defualt="-1" />
	<cfproperty name="PROMOTION" defualt="-1" />
	<cfproperty name="BASEPAY" defualt="-1" />
	<cfproperty name="COMP_LOCATION_FACTOR" defualt="1.00" />
	<cfproperty name="ACTIVE" defualt="-10131" />	
	<cfproperty name="I9_PENDING" defualt="-10157" />
	<cfproperty name="EMP_ADDRESS_TYPE" defualt="17" />
	<cfproperty name="REHIRE" defualt="3" />
	<cfproperty name="HOMEDIRECTORY" defualt="G:" />
	<cfproperty name="MAILSERVER" defualt="SCFMX" />
	<cfproperty name="ES_REASON_NEW_HIRE" defualt="5" /><!---ES=EMPLOYMENT--->
	<cfproperty name="PS_REASON_NEW_HIRE" defualt="53" /><!---PS=PAY--->	
	<cfproperty name="PP_REASON_NEW_HIRE" defualt="44" /><!---PP=POSITION--->
	<cfproperty name="ES_REHIRE" defualt="6" /><!---ES=EMPLOYMENT--->
	<cfproperty name="PS_REHIRE" defualt="54" /><!---PS=PAY--->
	<cfproperty name="PP_REHIRE" defualt="45" />
	<cfproperty name="EmployeeInfo" defualt="" />
	<cfproperty name="Mirror" defualt="EPARBasic" />
	<cfproperty name="SCF" defualt="Southcentral Foundation" />
    <cfproperty name="NewUserID" defualt="" />
	<cfproperty name="NewADGUID" defualt="" />
	<cfproperty name="NewHRPersonIDNo" defualt="" />
	<cfproperty name="HRSupervisorID" defualt="" />
	<cfproperty name="NewRosettaID" defualt="-1" />
    
	<cffunction name="init" access="public" output="false" returntype="Creation">
        <cfargument name="StepID" type="string" required="false" default="-1" />
		<cfscript>
		    mainQueries = CreateObject("component", "queries");
			setStepID(ARGUMENTS.StepID);			
			this.EmployeeInfo = mainQueries.funcGetEmpInfo(getStepID());
			this.DOMAINCONTROLLER = "10.100.1.101";
			this.ORG_SCF = 117;			
			this.DOLLARS = 2;
			this.USA = 5;
			this.Error = 0;
			this.EmpStatusReason = '';
			this.ErrorMessage = '';
			this.Manual = 0;
			this.PRIMARY_POS = -1;
			this.PROMOTION = -1;
			this.BASEPAY = -1;
			this.COMP_LOCATION_FACTOR = 1.0;			
			this.ACTIVE = -10131;
			this.I9_PENDING = -10157;
			this.EMP_ADDRESS_TYPE = 17;
			this.REHIRE = 3;
			this.HOMEDIRECTORY = 'G:';
			this.MAILSERVER = 'SCFMX';			
			this.ES_REASON_NEW_HIRE = 5;
			this.PS_REASON_NEW_HIRE = 53;
			this.PP_REASON_NEW_HIRE = 44;
			this.ES_REHIRE = 6;
			this.PS_REHIRE = 54;			
			this.PP_REHIRE = 45;
			this.Mirror = "EPARBasic";
			this.SCF = 'Southcentral Foundation';
			this.NewADGUID = this.EmployeeInfo.ADGUID;
			this.NewUserID = this.EmployeeInfo.ADUserID;
			this.NewHRPersonIDNo = this.EmployeeInfo.HRPersonIDNo;
			this.ReHirePersonIDNo = this.EmployeeInfo.HRPersonIDNo;
			this.HRSupervisorID = this.EmployeeInfo.SupervisorID;
			this.NewRosettaID = this.EmployeeInfo.RosettaID;
			this.EmployeeNameDisplay = "#trim(this.EmployeeInfo.First)# #trim(this.EmployeeInfo.Middle)# #trim(this.EmployeeInfo.Last)#";
			return this;
		</cfscript>
	</cffunction>    
      
        
    <cffunction name="getStepID" access="public" output="false" returntype="string">
        <cfreturn this.StepID />
    </cffunction>
    
    
    <cffunction name="setStepID" access="public" output="false" returntype="any">
        <cfargument name="StepID" type="string" required="false" default="-1" />
		<cfset mainQueries = CreateObject("component", "queries") />
		<cfset step3Queries = CreateObject("component", "#session.rootDir#.cfc.step3Queries") />
        <cftry>
	        <cfscript>
	            this.StepID = ARGUMENTS.StepID;
				this.EmployeeInfo = mainQueries.funcGetEmpInfo(this.StepID);
				this.Depts = mainQueries.funcGetDepts();
				this.PositionInfo = mainQueries.funcGetPositionCodes(this.EmployeeInfo.PositionID);
				this.EmpECInfo = mainQueries.funcGetEmployeeContacts(this.EmployeeInfo.ID, 2); 
				this.AF = mainQueries.funcGetAF(this.EmployeeInfo.FrequencyID); //tSY_PAY_RATE_FREQUENCY_CODES
				this.Position =  mainQueries.funcGetPositions(this.EmployeeInfo.PositionID);
				this.Dept = mainQueries.funcGetDepts(this.EmployeeInfo.DeptID);
				this.NextMailServer = mainQueries.funcGetNextMailServer();
				this.Container = mainQueries.funcGetContainer(this.EmployeeInfo.ContainerID);
				this.Supervisor = mainQueries.SCF_Employee_GetEmployeeInfo_Basic(this.EmployeeInfo.SupervisorID);
				this.CreationOU = "OU=" & #this.Container.Container# & ";";
                this.NewADGUID = this.EmployeeInfo.ADGUID;
                this.NewUserID = this.EmployeeInfo.ADUserID;
                this.NewHRPersonIDNo = this.EmployeeInfo.HRPersonIDNo;
                this.ReHirePersonIDNo = this.EmployeeInfo.HRPersonIDNo;
                this.HRSupervisorID = this.EmployeeInfo.SupervisorID;
                this.NewRosettaID = this.EmployeeInfo.RosettaID;
	        </cfscript>

        <cfcatch type="any">
            <cfset this.ErrorMessage = CFCATCH />
        </cfcatch>
        </cftry>       
        <cfreturn />
    </cffunction>
    
  
    <cffunction name="ADCreation" access="public" output="false" returntype="any">
        <!---
        <cfldap action="add" 
        attributes="#attributeList#" 
        dn="CN=XXXTxxx, OU=SCF, ou=SCFUsers, dc=SouthcentralFoundation, dc=com" 
        server="10.100.1.101"
        username="scf\Userlist" 
        password="DefinedMan" >
        --->
		<cfscript>
			Var mainQueries = CreateObject("component", "queries");
			Var step3Queries = CreateObject("component", "step3Queries");
			Var ADResult = '';
			Var Success = '';
			Var Warning = 0;
			Var Next = '';
			Var retObj = {Status = 'None', Message = '', Result = 0};
			Var ADAttributeList = "objectClass=top, person, organizationalPerson, user;ou=SCFUsers";
			//Var DN = "CN=" & this.EmployeeInfo.Last & ", OU=SCF, ou=SCFUsers, dc=SouthcentralFoundation, dc=com";			
		</cfscript>
        <cfobject type="dotnet" name="ADCreation" class="ADTools.Creation" assembly ="C:\Program Files\Southcentral Foundation\ADTools\ADTools.dll">
        <cfinclude template="/code_lib/SCF_ActiveDirectory.cfc">        
        <cftry>        
            <cfset ADResult = ADCreation.CreateUser(
				#this.DOMAINCONTROLLER#, 
				#replace(this.EmployeeInfo.First," ","")#, 
				#this.EmployeeInfo.Middle#, 
				#replace(this.EmployeeInfo.Last," ","")#,
				#this.EmployeeInfo.PreferredName#,
				#this.Supervisor.Email#, 
				#this.SCF#, 
				#this.Dept.OrganizationDescription#, 
				#this.Position.PositionCodeDescription#, 
				#this.Position.PositionCodeDescription# & '(' & #trim(this.Position.PositionCode)# & ')' , 
				#this.Container.HomeDir#,
				#this.HOMEDIRECTORY#, 
				#this.NextMailServer.ServerName#, 
				"OU=" & #this.Container.Container# & ";", 
				#this.EmployeeInfo.DeskPhone#, 
				#this.Mirror#, 
				"", 
				10000)/>			
			<cfif ADResult NEQ 0>			            
			    <cfset ADResult = replace(replace(replace(replace(ADCreation.GetErrorText(),chr(13),'<BR/>','all'), chr(10), '','all'),'<BR/>',''),'<BR/><BR/>','')  />			      
			    <cfif ADResult EQ -2><!---Warning only--->			    
			        <cfset Warning = 1 />
                    <cfset retObj.Status = 'Created' />
			        <cfset Success = 1 />
					<cfset retObj.Result = 1 />
			    <cfelse>
                    <cfset retObj.Status = 'Fail' />
			        <cfset retObj.Result = 1 />
					<cfset Success = 0 />		        
			    </cfif>                            
			<cfelse>			  
			    <cfset retObj.Status = 'Created' />
				<cfset Success = 1 />
				<cfset retObj.Result = 1 />
			</cfif>			
			<cfif Success >
                <cfset this.NewUserID = ADCreation.GetNewLogin()/>
				<cfset this.NewADGUID = ADCreation.GetGUID(this.NewUserID, "", "")/>
                <cfquery name="qryUpdateAction" datasource="#Session.DataSource#">
                    Update Employee Set ADUserID = '#this.NewUserID#' Where ID = #this.EmployeeInfo.ID#
                </cfquery>
				<cfif this.NextMailServer.ServerID GTE 3>
                    <cfset Next = 1>
                <cfelse>        
                    <cfset Next = this.NextMailServer.ServerID + 1>
                </cfif>
				<cfset step3Queries.funcUpdateNextServer(Next) />
				<cfset retObj.Message = "<strong>Account Created Successfully</strong>" />
				<cfif Warning >                
                     <cfset retObj.Message = retObj.Message & "<BR><u>WARNING</u>:&nbsp;&nbsp;" />                     
                </cfif>
				<cfset ADResult = retObj.Message & ADResult />
				<cfset this.Error = 0 />				
				<cfif Warning >
	                <!--- Send notice to the helpdesk that some action is required --->
				    <cfset retObj.Status = 'Fail' />
                    <cfset retObj.Message &= '<strong>Error generating the Active Directory record for #this.EmployeeInfo.First# #this.EmployeeInfo.Last#</strong><BR /><BR />
					   #retObj.Message#<br /><br />
					    Result: #retObj.Result# #ADResult#' />
                    <cfset ErrorEmail("EPAR Warning:  Creating Active Directory Account", retObj.Message) />	            
	            </cfif>
	        <cfelse>				
				<cfset this.NewUserID = "">
	            <cfset this.Error = 1 />	           	                                     
	            <cfset retObj.Status = 'Fail' />
	            <cfset retObj.Message = retObj.Message & 'Error generating the Active Directory record<br />' & 
                    'Result:' & retObj.Result & ' ' & ADResult & '<BR />' &
                    "DLL Call: ADCreation.CreateUser(#this.DOMAINCONTROLLER#,#replace(this.EmployeeInfo.First," ","")#,#this.EmployeeInfo.Middle#,#replace(this.EmployeeInfo.Last," ","")#,
                    #this.EmployeeInfo.PreferredName#,#this.Supervisor.Email#,#this.SCF#,#this.Dept.OrganizationDescription#,#this.Position.PositionCodeDescription#,#this.Position.PositionCodeDescription# & '(' & #trim(this.Position.PositionCode)# & ')' , 
                    #this.Container.HomeDir#,#this.HOMEDIRECTORY#,#this.NextMailServer.ServerName#,'OU=' & #this.Container.Container# & ';',#this.EmployeeInfo.DeskPhone#, 
                    #this.Mirror#, '',10000)" />
				 <cfset ErrorEmail("EPAR Warning:  Creating Active Directory Account", retObj.Message) />	
			</cfif>
	        <cfcatch type="any">
	            <!---<cfldap action="DELETE" server="10.100.1.101" DN="" username="scf\Userlist" password="DefinedMan"/>--->
                <cfset retObj.Status = 'Fail' />
                <cfset retObj.Result &= ' Message: #replace(CFCATCH.message,"'","\'","all")#<BR/>Detail: #replace(CFCATCH.Detail,"'","\'","all")#'  />
                <cfset retObj.Message = '<strong>Error generating the Active Directory record: #this.EmployeeInfo.First# #this.EmployeeInfo.Last#<BR /> 
                    Result:  #replace(retObj.Result,"\'","'","all")#<BR />
                    Action by User (Rosetta ID): #Session.intUserRosettaID#</strong><br /><br />' />
               <cfset ErrorEmail("EPAR Error:  Error generating the Active Directory record", retObj.Message) />                
                <Cfreturn  retObj />    
	        </cfcatch>                    
        </cftry>
        
        <Cfreturn  retObj />
    </cffunction> 
    
    
    <cffunction name="HRCreation" access="public" output="false" returntype="any">
        <cfscript>
            Var mainQueries = CreateObject("component", "queries");
			Var step3Queries = CreateObject("component", "step3Queries");
            Var HRResult = '';
            Var Success = '';
            Var Warning = 0;
            Var SQL = '';
            Var retObj = {Status = 'None', Message = '', Result = 0};
        </cfscript>
		
        <cftry>        
            <cfset this.HRSupervisorID = mainQueries.SCF_HR_MasterID_to_HRPersonID(this.EmployeeInfo.SupervisorID) />
			<!--- REHIRE CHECK--->
            <cfset CheckRehire = step3Queries.funcCheckRehire(this.EmployeeInfo.SSN) />
			<cfset SQL = "funcCheckRehire(this.EmployeeInfo.SSN)" />
			<cfif CheckRehire.recordcount GT 0>
                <!--- Person already exists in our system ... DERP!!! REHIRE --->
                <cfset CreateEmployeeRehire = funcCreateEmployeeRehire() />
				<cfset SQL = "funcCreateEmployeeRehire()" />
				<cfset this.ReHirePersonIDNo = CheckRehire.PersonIDNo />
                <cfset this.NewHRPersonIDNo = CheckRehire.PersonIDNo /><!--- For check later in Rosetta creation--->
                <cfquery name="qryUpdateAction" datasource="#Session.DataSource#">
                    Update Employee Set HRPersonIDNo=#this.NewHRPersonIDNo# Where ID = #this.EmployeeInfo.ID#
                </cfquery>
				<cfset HRResult = CreateEmployeeRehire.ErrorCheck.Error>
				<cfif HRResult EQ 0>
				    <!---Step 1 (Rehiring the Employee) was successful, now let's move on to Step 2, Adding Addresses and Phone Numbers--->
					<cfset PrimaryPhones = step3Queries.funcUpdatePrimaryPhones(this.ReHirePersonIDNo, dateformat(dateadd('d', -1, this.EmployeInfo.ActStartDate),'mm/dd/yyyy') )/>
					<cfset SQL = "scf_SCFVM18_CreationStep2_AddressesPhones 
						#this.NewHRPersonIDNo#,'#this.EmployeeInfo.ActStartDate#',#this.EMP_ADDRESS_TYPE#,'#this.EmployeeInfo.Address1#', 
						'#this.EmployeeInfo.Address2#','#this.EmployeeInfo.City#',#this.EmployeeInfo.State#,'#this.EmployeeInfo.ZIP#', 
						#this.USA#,'#this.EmployeeInfo.HomePhone#','#this.EmployeeInfo.CellPhone#','#this.EmployeeInfo.WorkPhone#', 
						'#this.EmployeeInfo.WorkPhoneExt#',#this.EmployeeInfo.PhonePrimaryID#"/>
                    <cfset CreateEmployeeRehireAddressesPhones = funcCreateEmployeeAddressesPhones()/>
					<cfset SQL = "funcCreateEmployeeAddressesPhones()" />
					<cfset HRResult = CreateEmployeeRehireAddressesPhones.Error />
					<cfif HRResult EQ 0>
                        <!---Step 2 was successful, now let's move on to Step 3, Emergency Contacts --->
						<cfset CreateEmployeeEmergencyContact = funcCreateEmployeeEmergencyContact()/>
						<cfset SQL = "funcCreateEmployeeEmergencyContact()" />
						<cfif CreateEmployeeEmergencyContact.HRResult EQ ''>	                    
	                        <cfset retObj.Result = 0 />	                        
	                    </cfif>
						<cfif HRResult EQ ''>
                            <cfset retObj.Result = 0>
                        </cfif>
                    <cfelse>
					   <!--- Error.  Don't proceed.  Post a description of what was successful and what must still be done by hand --->
					   <cfset HRResult &= "The rehire action on HR record was successful but there was an error adding the Employee\'s address(es) and phone(s).  
					   The Address(es) and Phone(s) and Emergency Contacts (if any) must still be added.  Please check the record in the Kronos HR tools and fix manually if necessary.<BR/>"/>
					</cfif>
				</cfif>
			<cfelse>
                <!--- HIRE NORMALLY --->
				<cfset SQL = "funcCreateEmployee()" />
                <cfset CreateEmployee = funcCreateEmployee()/>
                <cfset HRResult = CreateEmployee.ErrorCheck.Error />
				<cfif HRResult EQ 0>
				    <!---Step 1 (Creating the employee Record was successful, now let's move on to Step 2, Adding Addresses and Phone Numbers--->
					<cfset this.NewHRPersonIDNo = CreateEmployee.NewID.COMPUTED_COLUMN_1 />
                    <cfquery name="qryUpdateAction" datasource="#Session.DataSource#">
                        Update Employee Set HRPersonIDNo=#this.NewHRPersonIDNo# Where ID = #this.EmployeeInfo.ID#
                    </cfquery>
					<cfset SQL = "scf_SCFVM18_CreationStep2_AddressesPhones 
                        #this.NewHRPersonIDNo#,'#this.EmployeeInfo.ActStartDate#',#this.EMP_ADDRESS_TYPE#,'#this.EmployeeInfo.Address1#', 
                        '#this.EmployeeInfo.Address2#','#this.EmployeeInfo.City#',#this.EmployeeInfo.State#,'#this.EmployeeInfo.ZIP#', 
                        #this.USA#,'#this.EmployeeInfo.HomePhone#','#this.EmployeeInfo.CellPhone#','#this.EmployeeInfo.WorkPhone#', 
                        '#this.EmployeeInfo.WorkPhoneExt#',#this.EmployeeInfo.PhonePrimaryID#"/>
					<cfset CreateEmployeeAddressesPhones = funcCreateEmployeeAddressesPhones()/>
					<cfset HRResult = CreateEmployeeAddressesPhones.Error />
					<cfif HRResult EQ 0>
                        <!---Step 2 was successful, now let's move on to Step 3, Emergency Contacts --->
						<cfset CreateEmployeeEmergencyContact = funcCreateEmployeeEmergencyContact()/>
						<cfif CreateEmployeeEmergencyContact.HRResult EQ ''>
	                        <cfset retObj.Result = 0 />                            
                        </cfif>
				    <cfelse>
				        <!--- Error.  Don't proceed.  Post a description of what was successful and what must still be done by hand --->
                        <cfset HRResult &= "The initial HR record creation was successful but there was an error adding the Employee\'s address(es) and phone(s).  
                        The Address(es) and Phone(s) and Emergency Contacts (if any) must still be added.  Please check the record in the Kronos HR tools and fix manually if necessary.<BR/>" />
						<cfset retObj.Status = 'Fail' />
					</cfif>
			    <cfelse>
                    <!--- Error.  Don't proceed.  Post a description of what was successful and what must still be done by hand --->  
                    <cfset HRResult &= "There  was an error creating the initial HR record for the Employee.  
                    The Employment Status, Pay, Personal Information, Address(es), Phone(s) and Emergency Contacts (if any) may still need to be added.  
                    Please check the record in the Kronos HR tools and fix manually if necessary.<BR/>" />
					<cfset retObj.Status = 'Fail' />
				</cfif>
			</cfif>
			<!---End hire/rehire--->
			
			<cfif retObj.Result NEQ 0>
                <cfset HRResult = 'Failed to complete Kronos HR record creation:<BR/>' & HRResult />
				<cfset retObj.Message = "Error generating the Kronos HR Prod record: <BR />#replace(HRResult,"\'","'","all")#<BR /><BR />
	                Step ID: #this.StepID#<BR />
	                Action by User (Rosetta ID): #Session.intUserRosettaID#<BR/>
	                SQL: #SQL#" />
				<cfset retObj.Status = "Fail" />
				<cfset ErrorEmail("EPAR Error:  Creating Kronos HR Prod Record", retObj.Message) />
            <cfelse>
                <cfset retObj.Status = "Complete" />
				<cfset retObj.Message = "<Strong>Success</Strong>" />
			</cfif>
            
            <cfcatch type="any">
                <cfset retObj.Status = 'Fail' />
				<!--- If it's a rehire and fails on the SQL, don't report an error to the Rosetta Thread.  We want to go ahead and add the Rosetta Record --->
                <cfif CFCATCH.message EQ "Error Executing Database Query." AND this.NewHRPersonIDNo NEQ 0>
                    <cfset this.Error = False />                    
                <cfelse>
                    <cfset this.Error = True />                    
                </cfif>
				<cfquery name="qryInsertErrorLog" datasource="#Session.DataSource#">
                    scf_InsertErrorLog #this.StepID#, #Session.intUserRosettaID#, N'Error generating the Kronos HR Prod record: #replace(HRResult,"\'","'","all")#'
                </cfquery>
                <cfset retObj.Result &= ' Message: #replace(CFCATCH.message,"'","\'","all")#<BR/>Detail: #replace(CFCATCH.Detail,"'","\'","all")#'  />
               <cfset retObj.Message = "Error generating the Kronos HR Prod record: <BR />#replace(retObj.Result,"\'","'","all")#<BR /><BR />
                    Step ID: #this.StepID#<BR />
                    Action by User (Rosetta ID): #Session.intUserRosettaID#<BR/>
                    SQL: #SQL#" />
                <cfset ErrorEmail("EPAR Error:  Creating Kronos HR Prod Record", retObj.Message) />
                <Cfreturn  retObj />    
            </cfcatch>                    
        </cftry>
        
        <Cfreturn  retObj />
    </cffunction>
    
    
    <cffunction name="RosettaCreation" access="public" output="true" returntype="any">
        <cfscript>
            Var mainQueries = CreateObject("component", "queries");
            Var step3Queries = CreateObject("component", "step3Queries");
            Var RosettaResult = '';
			Var RosettaID = 0;
			Var EPAR_ID = this.EmployeeInfo.ID;
            Var retObj = {Status = 'None', Message = '', Result = 0};        
        </cfscript>            
        <cftry>
        
            <cfset CreateRosettaRecord = funcCreateRosettaRecord() />
			<cfset this.RosettaID = CreateRosettaRecord.NewRosettaID />
            <cfquery name="qryUpdateAction" datasource="#Session.DataSource#">
                Update Employee Set RosettaID=#this.RosettaID# Where ID = #this.EmployeeInfo.ID#
            </cfquery>
			<cfif this.NewUserID NEQ '' and this.NewHRPersonIDNo EQ 0>
                <cfset RosettaResult = "The Rosetta Stone Record was created, but there was a problem creating the employee\'s HR record.  
	                The Network Account has been created. You\'ll need to manually add the employee to Kronos HR.  
	                After the employee has been added, please notify the Service Desk so that the mapping can be completed in Rosetta Stone." />
                <cfset retObj.Status = 'Created' />
                <cfset retObj.Message = "<strong>Account Created Successfully</strong><br />" & RosettaResult />
            <cfelseif this.NewUserID NEQ '' and this.NewHRPersonIDNo GT 0>
                <cfset retObj.Message = "<strong>Account Created Successfully</strong>" />
                <cfset retObj.Status = 'Created' />
				<cfmail bcc="#Session.ITS_EMAIL#" to="#mainQueries.SCF_Employee_GetEmployeeInfo_Basic(this.EmployeeInfo.SupervisorID).Email#" 
                    from="""HR Dept - EPAR System"" <noreply@scf.cc>"  type="html" subject="Employee Hire Update">
                    <p>The employee, <strong>#this.EmployeeNameDisplay#</strong>, is now in the SCF system.  
                        Here is some information regarding their status and user account.<BR />
                    </p>
                    <table>
                        <tr>
                            <td width='5'>&nbsp;</td>
                            <td>Network User Account:</td>
                            <td width=25>&nbsp;</td>
                            <td>#this.NewUserID#</td>
                        </tr>
                        <tr>
                            <td>&nbsp;</td>
                            <td>Password (required to change @ first login):</td>
                            <td>&nbsp;</td>
                            <td>Password10! (case sensitive)</td>
                        </tr>
                        <tr>
                            <td>&nbsp;</td>
                            <td>Date of Hire:</td>
                            <td>&nbsp;</td>
                            <td>#dateFormat(this.EmployeeInfo.ActStartDate, 'mm/dd/yyyy')#</td>
                        </tr>
                        <tr>
                            <td>&nbsp;</td>
                            <td>Desk Phone:<BR />(as it will appear in the Address Book)</td>
                            <td>&nbsp;</td>
                            <td>#this.EmployeeInfo.DeskPhone#</td>
                        </tr>
                        <tr>
                            <td>&nbsp;</td>
                            <td>Job Title:</td>
                            <td>&nbsp;</td>
                            <td>#this.PositionInfo.PositionCodeDescription#</td>
                        </tr>
                        <tr>
                            <td>&nbsp;</td>
                            <td> 
                                Home Directory:                             
                            </td>
                            <td>&nbsp;</td>
                            <td>#this.Container.HomeDir#\#this.NewUserID#</td>
                        </tr>
                    </table>                        
                </cfmail>
            <Cfelse>
                <cfset retObj.Message = "<strong>HRID was not passed!</strong>" />
                <cfset retObj.Status = 'Fail' />
			</cfif>
			
        <cfcatch type="any">
            <cfset retObj.Status = 'Fail' />            
            <cfset retObj.Result &= ' Message: #replace(CFCATCH.message,"'","\'","all")#<BR/>Detail: #replace(CFCATCH.Detail,"'","\'","all")#' />
            <cfset retObj.Message = 'EPAR Error:  Creating Rosetta Stone Record: #replace(retObj.Result,"\'","'","all")#<BR /><BR />
                Step ID: #this.StepID#<BR />
                Supervisor Email: #mainQueries.SCF_Employee_GetEmployeeInfo_Basic(this.EmployeeInfo.SupervisorID).Login#@scf.cc<BR />
                Action by User (Rosetta ID): #Session.intUserRosettaID#'  />
            <cfset InsertErrorLog = mainQueries.funcInsertErrorLog(this.StepID, Session.intUserRosettaID, 'Error creating the Rosetta Stone record: #CFCATCH.Detail#') />               
            <cfset ErrorEmail("Error creating the Rosetta Stone record",retObj.Message) />                
            <Cfreturn  retObj />    
        </cfcatch>                    
        </cftry>
        
        <Cfreturn  retObj />
    </cffunction>
    
    
    <cffunction name="CreationComplete" access="public" output="true" returntype="any">        
        <cftry>
            <cfset Step3UpdateAction = mainQueries.funcUpdateAction(this.StepID, Session.intUserRosettaID, 'Auto Generated') />
            <cfset Step3InsertAction = mainQueries.funcInsertAction(this.EmployeeInfo.ID, 5) />
            <cfset retObj = {Status = 'Created', Message = '<strong>Success</strong>'} />
                    
        <cfcatch type="any">
            <cfset retObj.Status = 'Fail' />
            <cfset retObj.Result &= ' Message: #replace(CFCATCH.message,"'","\'","all")#<BR/>Detail: #replace(CFCATCH.Detail,"'","\'","all")#' />
            <cfset retObj.Message = 'Error advancing the step: #CFCATCH.Detail#<BR /><BR />
                Step ID: #this.GetTermDetails.ActionStepID#  ... Step 4 to 5<BR />
                Action by User (Rosetta ID): #Session.intUserRosettaID#' />
            <cfset mainQueries.funcInsertErrorLog(this.GetTermDetails.ActionStepID, '#Session.intUserRosettaID#', 'Error Disabling TimeKeeper Record: #replace(retObj.Result,"\'","'","all")#')/>
            <cfset ErrorEmail("Error advancing the step", retObj.Message) />                
            <Cfreturn  retObj />    
        </cfcatch>                    
        </cftry>
        
        <Cfreturn  retObj />
    </cffunction>
		
	
	<cffunction name="funcCreateEmployeeRehire" returntype="any">
        <cfscript>
            Var mainQueries = CreateObject("component", "queries");
            Var retVal = {};
            Var Exempt = -1;
			Var Seasonal = -1;
			Var FullTime = -1;
			Var AnnualSalary = this.EmployeeInfo.PayRate * this.AF.AnnualizingFactor;
			Var HRSupID = SCF_HR_MasterID_to_HRPersonID( this.EmployeeInfo.SupervisorID );
			if(this.EmployeInfo.SalaryHourlyID EQ -10192){
                Exempt = -1;
			}else{
			    Exempt = 0;
			}
			if(this.EmployeInfo.Seasonal){
			    Seasonal = -1;
			}else{
			    Seasonal = 0;
			}
			if(this.EmployeInfo.FullTime){
			    FullTime = -1;
			}else{
			    FullTime = 0;
			}						
        </cfscript>           
        
        <cfstoredproc datasource="#Session.DataSource#" procedure="scf_SCFVM18_RehireStep1">  
            <cfprocparam cfsqltype="cf_sql_integer" value="#this.CheckRehire.PersonIDNo#"><!---@pintPersonIDNo --->
            <cfprocparam cfsqltype="cf_sql_integer" value="#this.EmployeInfo.PositionID#"><!---@pintPosID --->
            <cfprocparam cfsqltype="cf_sql_integer" value="#this.PP_REHIRE#"><!---@pintPosStatusID --->
            <cfprocparam cfsqltype="cf_sql_date" value="#this.EmployeInfo.ActStartDate#"><!---@pdteHire --->
            <cfprocparam cfsqltype="cf_sql_integer" value="#HRSupID#"><!---@pintHRSupID --->
            <cfprocparam cfsqltype="cf_sql_integer" value="#this.PRIMARY_POS#"><!---@pintPrimaryPos --Always (-1) --->
            <cfprocparam cfsqltype="cf_sql_integer" value="#this.PROMOTION#"><!---@pintPromotion --->
            <cfprocparam cfsqltype="cf_sql_integer" value="#Exempt#"><!---@pintExempt --->
            <cfprocparam cfsqltype="cf_sql_integer" value="#this.EmployeInfo.SalaryHourlyID#"><!---@pintSalaryHourlyID --->
            <cfprocparam cfsqltype="cf_sql_integer" value="#Seasonal#"><!---@pintSeasonal      --->
            <cfprocparam cfsqltype="cf_sql_integer" value="#this.EmployeInfo.HoursPerWeek#"><!---@pintHrsPerWk --->
            <cfprocparam cfsqltype="cf_sql_integer" value="#VAL(this.EmployeInfo.WorkersCompID)#"><!---@pintWrksCompID --->
            <cfprocparam cfsqltype="cf_sql_integer" value="#this.COMP_LOCATION_FACTOR#"><!---@pintCompLocFactor --->
            <cfprocparam cfsqltype="cf_sql_integer" value="#this.PS_REHIRE#"><!---@pintPayStatusID --->
            <cfprocparam cfsqltype="cf_sql_integer" value="#this.EmployeInfo.CompTypeID#"><!---@pintCompTypeID --->
            <cfprocparam cfsqltype="cf_sql_integer" value="#this.EmployeInfo.FrequencyID#"><!---@pintFreqID --->
            <cfprocparam cfsqltype="cf_sql_float" value="#this.EmployeInfo.PayRate#"><!---@pfltPayRate --->
            <cfprocparam cfsqltype="cf_sql_integer" value="#this.AF.AnnualizingFactor#"><!---@pintAnnualizingFactor --->
            <cfprocparam cfsqltype="cf_sql_float" value="#AnnualSalary#"><!---@pfltAnnualSalary --->
            <cfprocparam cfsqltype="cf_sql_integer" value="#this.BASEPAY#"><!---@pintBasePay --->
            <cfprocparam cfsqltype="cf_sql_integer" value="#this.DOLLARS#"><!---@pintDollars --->
            <cfprocparam cfsqltype="cf_sql_integer" value="#this.ACTIVE#"><!---@pintActive --->
            <cfprocparam cfsqltype="cf_sql_integer" value="#this.EmployeInfo.EmpCodeID#"><!---@pintEmploymentCodeID --->
            <cfprocparam cfsqltype="cf_sql_integer" value="#FullTime#"><!---@pintFullTime --->
            <cfprocparam cfsqltype="cf_sql_integer" value="#this.EmployeInfo.I9#"><!---@pintI9OnFileID --->
            <cfprocparam cfsqltype="cf_sql_integer" value="#this.ORG_SCF#"><!---@pintOrgID --->
            <cfprocparam cfsqltype="cf_sql_integer" value="#this.ES_REHIRE#"><!---@pintESID --->
            <cfprocparam cfsqltype="cf_sql_integer" value="#this.REHIRE#"><!---@pintAction --->
            <cfprocparam cfsqltype="cf_sql_date" value="#this.EmployeInfo.DOB#"><!---@pdteDOB --->
            <cfprocparam cfsqltype="cf_sql_varchar" value="#this.EmployeInfo.First#"><!---@pstrFirst --->
            <cfprocparam cfsqltype="cf_sql_varchar" value="#this.EmployeInfo.Last#"><!---@pstrLast --->
            <cfprocparam cfsqltype="cf_sql_integer" value="#this.EmployeInfo.MaritalStatusID#"><!---@pintMaritalStatusID --->
            <cfprocparam cfsqltype="cf_sql_varchar" value="#this.EmployeInfo.Middle#"><!---@pstrMiddle --->
            <cfprocparam cfsqltype="cf_sql_varchar" value="#this.EmployeInfo.PreferredName#"><!---@pstrPreferred --->
            <cfprocparam cfsqltype="cf_sql_integer" value="#this.EmployeInfo.EthnicID#"><!---@pintEthnicCodeID --->
            <cfprocparam cfsqltype="cf_sql_integer" value="#VAL(this.EmployeInfo.GenderID)#"><!---@pintGenderID --->
            <cfprocparam cfsqltype="cf_sql_varchar" value="#this.EmployeInfo.SSN#"><!---@pstrSSN --->
            <cfprocparam cfsqltype="cf_sql_varchar" value="#this.NewUserID#"><!---@pstrNewUserID --->
            <cfprocresult name="NewID" resultset="1">
            <cfprocresult name="ErrorCheck" resultset="2">
        </cfstoredproc>
		
        <cfset retVal.NewID = NewID /> 
        <cfset retVal.ErrorCheck = ErrorCheck />
        <cfreturn retVal />
    </cffunction>
		
	
	<cffunction name="funcCreateEmployeeAddressesPhones" returntype="any">
        <cfstoredproc datasource="#Session.DataSource#" procedure="scf_SCFVM18_CreationStep2_AddressesPhones">  
            <cfprocparam cfsqltype="cf_sql_integer" value="#this.NewHRPersonIDNo#" />, <!--- @pintPersonIDNo --->
            <cfprocparam cfsqltype="cf_sql_date" value="#this.EmployeeInfo.ActStartDate#" />, <!--- @pdteDOH --->
            <cfprocparam cfsqltype="cf_sql_integer" value="#this.EMP_ADDRESS_TYPE#" />, <!--- @pintAddressTypeID --->
            <cfprocparam cfsqltype="cf_sql_varchar" value="#this.EmployeeInfo.Address1#" />, <!--- @pstrAddress1 --->
            <cfprocparam cfsqltype="cf_sql_varchar" value="#this.EmployeeInfo.Address2#" />, <!--- @pstrAddress2 --->
            <cfprocparam cfsqltype="cf_sql_varchar" value="#this.EmployeeInfo.City#" />, <!--- @pstrCity --->
            <cfprocparam cfsqltype="cf_sql_integer" value="#this.EmployeeInfo.State#" />, <!--- @pintStateID --->
            <cfprocparam cfsqltype="cf_sql_varchar" value="#this.EmployeeInfo.Zip#" />, <!--- @pstrZIP --->
            <cfprocparam cfsqltype="cf_sql_integer" value="#this.USA#" />, <!--- @pintUSAID --->
            <cfprocparam cfsqltype="cf_sql_varchar" value="#this.EmployeeInfo.HomePhone#" />, <!--- @pstrHomePhone --->
            <cfprocparam cfsqltype="cf_sql_varchar" value="#this.EmployeeInfo.CellPhone#" />, <!--- @pstrCellPhone --->
            <cfprocparam cfsqltype="cf_sql_varchar" value="#this.EmployeeInfo.WorkPhone#" />, <!--- @pstrWorkPhone --->
            <cfprocparam cfsqltype="cf_sql_varchar" value="#this.EmployeeInfo.WorkPhoneExt#" />, <!--- @pstrWorkExt --->
            <cfprocparam cfsqltype="cf_sql_integer" value="#this.EmployeeInfo.PhonePrimaryID#" /><!--- @pintPrimaryPhoneID --->
            <cfprocresult name="ErrorCheck" resultset="1">
        </cfstoredproc>
        <cfreturn ErrorCheck />
    </cffunction>
	
	
    <cffunction name="funcCreateEmployeeEmergencyContact" returntype="any">
        <cfscript>
            Var retVal = {HRResult = ""};
			Var ContactOrder = 1;
		</cfscript>
                
        <cfloop query="this.EmpECInfo"> 
            
            <cfstoredproc datasource="#Session.DataSource#" procedure="scf_SCFVM18_CreationStep3_EmergencyContact">  
                <cfprocparam cfsqltype="cf_sql_integer" value="#this.NewHRPersonIDNo#" />, <!--- @pintPersonIDNo --->
                <cfprocparam cfsqltype="cf_sql_date" value="#this.EmployeeInfo.ActStartDate#" />, <!--- @pdteDOH --->
                <cfprocparam cfsqltype="cf_sql_varchar" value="#First#" />, <!--- @pstrFirst --->
                <cfprocparam cfsqltype="cf_sql_varchar" value="#Last#" />, <!--- @pstrLast --->
                <cfprocparam cfsqltype="cf_sql_integer" value="#RelationID#" />, <!--- @pintRelationID --->
                <cfprocparam cfsqltype="cf_sql_integer" value="#ContactOrder#" />,<!--- @pintContactOrder --->
                <cfprocparam cfsqltype="cf_sql_integer" value="#this.EMP_ADDRESS_TYPE#" />, <!---@pintAddressTypeID --->
                <cfprocparam cfsqltype="cf_sql_varchar" value="#Address1#" />, <!--- @pstrAddress1 --->
                <cfprocparam cfsqltype="cf_sql_varchar" value="#Address2#" />, <!---@pstrAddress2 --->
                <cfprocparam cfsqltype="cf_sql_varchar" value="#City#" />, <!--- @pstrCity --->
                <cfprocparam cfsqltype="cf_sql_varchar" value="#State#" />, <!--- @pintStateID --->
                <cfprocparam cfsqltype="cf_sql_varchar" value="#Zip#" />, <!--- @pstrZIP --->
                <cfprocparam cfsqltype="cf_sql_integer" value="#this.USA#" />, <!--- @pintUSAID --->
                <cfprocparam cfsqltype="cf_sql_varchar" value="#DisplayPhone(HomePhone)#" />, <!--- @pstrHomePhone --->
                <cfprocparam cfsqltype="cf_sql_varchar" value="#DisplayPhone(CellPhone)#" />,<!--- @pstrCellPhone --->
                <cfprocparam cfsqltype="cf_sql_varchar" value="#DisplayPhone(WorkPhone)#" />,<!--- @pstrWorkPhone --->
                <cfprocparam cfsqltype="cf_sql_varchar" value="#WorkPhoneExt#" />,<!--- @pstrWorkExt --->
                <cfprocparam cfsqltype="cf_sql_integer" value="#PhonePrimaryID#" /> <!---@pintPrimaryPhoneID --->
                <cfprocresult name="ErrorCheck" resultset="1">
            </cfstoredproc>
            
			<cfscript>
                if(ErrorCheck.Error NEQ 0){
				    retVal.HRResult &= "Error creating Emergency Contact record for #First# #Last#.  Please check the record in the Kronos HR tools and fix manually if necessary.<BR/>";
					retVal.Result = ErrorCheck.Error;
				}
                ContactOrder += 1;
			</cfscript>
        </cfloop>

        <cfreturn retVal />
    </cffunction>
	
	
	<cffunction name="funcCreateEmployee" returntype="any">
        <cfscript>
            Var AnnualSalary = this.EmployeeInfo.PayRate * this.AF.AnnualizingFactor;
			Var retVal = {};
        </cfscript>
        
        <cfstoredproc datasource="#Session.DataSource#" procedure="scf_SCFVM18_CreationStep1_CreateEmployee">  
            <cfprocparam cfsqltype="cf_sql_date" value="#this.EmployeeInfo.DOB#"><!--- @pdteDOB --->
            <cfprocparam cfsqltype="cf_sql_date" value="#this.EmployeeInfo.ActStartDate#"><!--- @pdteDOH --->
            <cfprocparam cfsqltype="cf_sql_varchar" value="#this.EmployeeInfo.First#"><!--- @pstrFirst --->
            <cfprocparam cfsqltype="cf_sql_varchar" value="#this.EmployeeInfo.Last#"><!--- @pstrLast --->
            <cfprocparam cfsqltype="cf_sql_varchar" value="#this.EmployeeInfo.PreferredName#"><!--- @pstrPreferred --->
            <cfprocparam cfsqltype="cf_sql_varchar" value="#this.EmployeeInfo.Middle#"><!--- @pstrMI --->
            <cfprocparam cfsqltype="cf_sql_varchar" value="#this.EmployeeInfo.SSN#"><!--- @pstrSSN --->
            <cfprocparam cfsqltype="cf_sql_integer" value="#this.EmployeeInfo.MaritalStatusID#"><!--- @pintMaritalStatusID --->
            <cfprocparam cfsqltype="cf_sql_integer" value="#this.EmployeeInfo.EthnicID#"><!--- @pintEthnicID --->
            <cfprocparam cfsqltype="cf_sql_integer" value="#this.EmployeeInfo.GenderID#"><!--- @pintGenderID --->
            <cfprocparam cfsqltype="cf_sql_integer" value="#this.EmployeeInfo.PositionID#"><!--- @pintPosID --->
            <cfprocparam cfsqltype="cf_sql_integer" value="#this.PP_REASON_NEW_HIRE#"><!--- @pintPosReasonID --->
            <cfprocparam cfsqltype="cf_sql_integer" value="#this.EmployeeInfo.SupervisorID#"><!--- @pintSupervisorID --->
            <cfprocparam cfsqltype="cf_sql_integer" value="#this.PRIMARY_POS#"><!--- @pintPrimaryPos --->
            <cfprocparam cfsqltype="cf_sql_integer" value="#this.PROMOTION#"><!--- @pintPomotion --->
            <cfprocparam cfsqltype="cf_sql_integer" value="#this.EmployeeInfo.Exempt#"><!--- @pintExempt --->
            <cfprocparam cfsqltype="cf_sql_integer" value="#this.EmployeeInfo.SalaryHourlyID#"><!--- @pintSalaryHourlyID --->
            <cfprocparam cfsqltype="cf_sql_integer" value="#this.EmployeeInfo.Seasonal#"><!--- @pintSeasonal --->
            <cfprocparam cfsqltype="cf_sql_integer" value="#this.EmployeeInfo.HoursPerWeek#"><!--- @pintHrsPerWk --->
            <cfprocparam cfsqltype="cf_sql_integer" value="#VAL(this.EmployeeInfo.WorkersCompID)#"><!--- @pintWkrsCompID --->
            <cfprocparam cfsqltype='cf_sql_float' value="#this.COMP_LOCATION_FACTOR#"><!--- @pfltCompLocationFactor --->
            <cfprocparam cfsqltype="cf_sql_integer" value="#this.ACTIVE#"><!--- @pintEmployeeStatusIDNo --->
            <cfprocparam cfsqltype="cf_sql_integer" value="#this.EmployeeInfo.FullTime#"><!--- @pintFullTime --->
            <cfprocparam cfsqltype="cf_sql_integer" value="#this.I9_PENDING#"><!--- @pintI9PendingID --->
            <cfprocparam cfsqltype="cf_sql_integer" value="#this.ORG_SCF#"><!--- @pintOrgCodeID --->
            <cfprocparam cfsqltype="cf_sql_integer" value="#this.EmployeeInfo.EmpCodeID#"><!--- @pintEmploymentCodeID --->
            <cfprocparam cfsqltype="cf_sql_integer" value="#this.EmployeeInfo.I9#"><!--- @pintI9OnFileID --->
            <cfprocparam cfsqltype="cf_sql_integer" value="#this.ES_REASON_NEW_HIRE#"><!--- @pintEmploymentStatusReasonID --->
            <cfprocparam cfsqltype="cf_sql_integer" value="#this.PS_REASON_NEW_HIRE#"><!--- @pintPayReasonID --->
            <cfprocparam cfsqltype="cf_sql_integer" value="#this.EmployeeInfo.CompTypeID#"><!--- @pintCompTypeID --->
            <cfprocparam cfsqltype="cf_sql_integer" value="#this.EmployeeInfo.FrequencyID#"><!--- @pintFrequencyID --->
            <cfprocparam cfsqltype="cf_sql_float" value="#this.EmployeeInfo.PayRate#"><!--- @pfltPayRate --->
            <cfprocparam cfsqltype="cf_sql_integer" value="#this.AF.AnnualizingFactor#"><!--- @pintAnnualizingFactor --->
            <cfprocparam cfsqltype="cf_sql_float" value="#AnnualSalary#"><!--- @pfltAnnualSalary --->
            <cfprocparam cfsqltype="cf_sql_integer" value="#this.BASEPAY#"><!--- @pintBasePay --->
            <cfprocparam cfsqltype="cf_sql_integer" value="#this.DOLLARS#"><!--- @pintCurrencyID --->
            <cfprocparam cfsqltype="cf_sql_varchar" value="#this.NewUserID#"><!--- @pstrNewUserID --->
            <cfprocresult name="NewID" resultset="1">
            <cfprocresult name="ErrorCheck" resultset="2">
        </cfstoredproc>
		
        <cfset retVal.NewID = NewID /> 
        <cfset retVal.ErrorCheck = ErrorCheck />

        <cfreturn retVal />
    </cffunction>


    <cffunction name="funcCreateRosettaRecord" returntype="any">  
        <cfquery name="qryCreateRosettaRecord" datasource="#Session.DataSourceRosetta#">                            
            Insert into RosettaStone (
                UserAccount, AD_GUID, HRProd_PersonIDNo, EPAR_ID, [Disabled]
            )
            Values (
                <cfif this.NewUserID NEQ ''><cfqueryparam cfsqltype="cf_sql_varchar" value="#this.NewUserID#" /><cfelse>NULL</cfif>, 
                <cfif this.NewADGUID NEQ ''><cfqueryparam cfsqltype="cf_sql_varchar" value="#this.NewADGUID#" /><cfelse>NULL</cfif>, 
                <cfif this.NewHRPersonIDNo NEQ 0 OR this.NewHRPersonIDNo NEQ ''><cfqueryparam cfsqltype="cf_sql_integer" value="#this.NewHRPersonIDNo#" /><cfelse>NULL</cfif>, 
                <cfif this.EmployeeInfo.ID NEQ 0 OR this.EmployeeInfo.ID NEQ ''><cfqueryparam cfsqltype="cf_sql_integer" value="#this.EmployeeInfo.ID#" /><cfelse>NULL</cfif>, 
                0
            )
            
            SELECT @@Identity AS NewRosettaID
        </cfquery>
        
        <cfreturn qryCreateRosettaRecord />
    </cffunction>
	
        
    <cffunction name="ErrorEmail" access="private" output="false" returntype="void">
        <cfargument name="EmailSubject" type="string" required="false" default="EPAR Error" />
        <cfargument name="EmailBody" type="string" required="false" default="" />
        
        <cfmail to=#Session.SERVICEDESK_EMAIL# From="EPAR_Error@scf.cc" subject="#ARGUMENTS.EmailSubject#" type="html">
            #ARGUMENTS.EmailBody#	        
	    </cfmail>                
    </cffunction>
    
    
    <cffunction name="AlertEmail" access="public" output="false" returntype="void">
        <cfargument name="EmailSubject" type="string" required="false" default="EPAR Error" />
        <cfargument name="EmailBody" type="string" required="false" default="" />
        <cfargument name="From" type="string" required="false" default="EPAR_Termination@scf.cc" />
        <cfargument name="To" type="string" required="false" default="#Session.SERVICEDESK_EMAIL#" />        
        <cfmail to=#ARGUMENTS.To# From="#ARGUMENTS.From#" subject="#ARGUMENTS.EmailSubject#" type="html">            
            #ARGUMENTS.EmailBody#            
        </cfmail>                
    </cffunction>    
    
   
</cfcomponent>